class Ford(object):
    def __init__(self):
        self.type = 'ford'
 
    def ford_run(self):
        print('%s is running' % self.type)
 
    def ford_turn(self):
        print('%s is turning' % self.type)
 
    def ford_stop(self):
        print('%s is stopping' % self.type)
 
 
class Buick(object):
    def __init__(self):
        self.type = 'buick'
 
    def buick_run(self):
        print('%s is running' % self.type)
 
    def buick_turn(self):
        print('%s is turning' % self.type)
 
    def buick_stop(self):
        print('%s is stopping' % self.type)
 
 
class AutoSystem(object):
 
    def __init__(self, car):
        self.car = car
 
    def car_run(self):
        if self.car.type == 'ford':
            self.car.ford_run()
        else:
            self.car.buick_run()
            
    def car_turn(self):
        if self.car.type == 'ford':
            self.car.ford_turn()
        else:
            self.car.buick_turn()
 
    def car_stop(self):
        if self.car.type == 'ford':
            self.car.ford_stop()
        else:
            self.car.buick_stop()
 
 
if __name__ == '__main__':
    ford = Ford()
    buick = Buick()
    autosystem = AutoSystem(ford)
    autosystem.car_run()
    autosystem.car_turn()
    autosystem.car_stop()
    autosystem.car = buick
    print('*'*100)
    autosystem.car_run()
    autosystem.car_turn()
    autosystem.car_stop()